home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_11_05
/
1105085b
< prev
next >
Wrap
Text File
|
1993-02-27
|
469b
|
25 lines
// fv1.cpp - a dynamic vector of float (with a possibly
// non-zero low-bound) using a subscripting object
// implemented by inheritance from float_array
#include "fv1.h"
#include <assert.h>
float float_vector::operator[](int i) const
{
assert(i >= low());
const float_array *fa = this;
return (*fa)[i - low()];
}
fa_index float_vector::operator[](int i)
{
assert(i >= low());
float_array *fa = this;
return (*fa)[i - low()];
}